<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="UTF-8">
	<title>红酒会 - 智能红酒管家</title>
	<link rel="shortcut icon" type="image/x-icon" href="${ctx}/favicon.ico" />
	<%-- <link type="text/css" rel="stylesheet" href="${ctx}/static/styles/bootstrap.min.css" /> --%>
	<link rel="stylesheet" href="http://libs.baidu.com/bootstrap/2.3.2/css/bootstrap.min.css" />
	
	
</head>
<body>
	
	<c:import url="/header"><c:param name="module">talk</c:param></c:import>
	<c:import url="/talk/right" />
	
<!--outWrap-->
<div class="outWrap">
	<div class="spekBoxIn">
        <div class="spek_Cont">
            <div class="speakHeader">
				<div class="snewL">
					<c:forEach var="tag" items="${hotTagList}">
  						<a href="${ctx}/talk/tag/${tag.id}">${tag.name}</a>
  					</c:forEach>
				</div>
           	  	<div class="snewR">
                	<input class="sdc_btn" type="button" onclick="location.href='${ctx}/talk/create?redirectUrl=/talk/create'" />
              	</div>
          	</div>
          
          	<div class="speakList">
          		<div class="ListImgBox">
            		<img src="${ctx}/static/images/speakcontimg.jpg" alt="">
                	<div class="timeC">
                		<span class="day">
                			<fmt:formatDate value="${recommend.editTime}" pattern="dd"/>
                		</span>
                		<span class="mon">
                			<fmt:formatDate value="${recommend.editTime}" pattern="1月"/>
                		</span>
                	</div>
            	</div>
          		<h2><a href="#" target="_blank">${recommend.title}</a></h2>
          		<p>${recommend.summary}</p>
          		<div class="speakdis">
            		<span class="spPL">评论(${recommend.commentCount})</span>
                	<span class="spAT">${recommend.user.username}</span>
            		<div class="bqR">
            			<c:set var="tags" value="${fn:split(recommend.tagStr, ';')}" />
						<c:forEach var="tag" items="${tags}" varStatus="stat">
							<c:if test="${stat.index < 5}">
								<a href="${ctx}/talk/tag/${fn:split(tag, ':')[0]}" class="tag">${fn:split(tag, ':')[1]}</a>
							</c:if>
						</c:forEach>
						<c:if test="${fn:length(tags) > 5}">
							<a href="javascript:;" class="more">更多...</a>
						</c:if>
            		</div>
            	</div>
            	
            	<c:forEach var="list" items="${page.content}">
            		<h2><a href="#" style="padding-top:10px;">${list.title}</a></h2>
	          		<p>${list.summary}</p>
	          		<div class="speakdis">
	            		<span class="spPL">评论(${list.commentCount})</span>
	                	<span class="spAT">${list.user.username}</span>
	            		<div class="bqR">
	            			<c:if test="${not empty list.tagStr}">
	            				<c:set var="tags" value="${fn:split(list.tagStr, ';')}" />
								<c:forEach var="tag" items="${tags}" varStatus="stat">
									<c:if test="${stat.index < 5}">
										<a href="${ctx}/talk/tag/${fn:split(tag, ':')[0]}" class="tag">${fn:split(tag, ':')[1]}</a>
									</c:if>
								</c:forEach>
								<c:if test="${fn:length(tags) > 5}">
									<a href="#tag${list.id}">展开...</a>
								</c:if>
	            			</c:if>
	            		</div>
	            	</div>
            	</c:forEach>
          	</div>
		</div>
	</div>
</div>

<c:import url="/WEB-INF/views/footer.jsp" />

<script type="text/javascript" src="http://libs.baidu.com/bootstrap/2.3.2/js/bootstrap.min.js"></script>

</body>
</html>
